Package com.amazon.A3L.messaging
Class RemoteMessage
- java.lang.Object
-
- com.amazon.A3L.messaging.RemoteMessage
-
public class RemoteMessage extends java.lang.ObjectRemote Message object used by developers to access message sent from app server The class is similar to FCM Remote Message have similar methods too
-
-
Constructor Summary
Constructors Constructor Description RemoteMessage()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static RemoteMessagecreateRemoteMessage(android.content.Intent intent)Create A3L RemoteMessage from intent received by A3Ljava.lang.StringgetCollapseKey()Gets the collapse key of the messagejava.util.Map<java.lang.String,java.lang.String>getData()Gets data message payload sent by developer as key-value pairjava.lang.StringgetFrom()Get the sender of this messagejava.lang.StringgetMessageId()Gets the message's IDjava.lang.StringgetMessageType()Gets the type of messageNotificationgetNotification()Gets the notification from message if setintgetOriginalPriority()Gets the original priority of messageintgetPriority()Gets the priority of message as deliveredjava.lang.StringgetRemoteMessageType()Gets RemoteMessagePlatform type whether ADM_REMOTE_MESSAGE or FCM_REMOTE_MESSAGEjava.lang.StringgetSenderId()Gets the Sender ID for the sender of this messagelonggetSentTime()Gets the time in milliseconds from the Epoch that the message was sentjava.lang.StringgetTo()Gets the message destinationintgetTtl()Gets the message time to live (TTL) in seconds
-
-
-
Method Detail
-
createRemoteMessage
public static RemoteMessage createRemoteMessage(@NonNull android.content.Intent intent)
Create A3L RemoteMessage from intent received by A3L- Parameters:
intent- : Intent- Returns:
- A3L RemoteMessage object
-
getRemoteMessageType
public java.lang.String getRemoteMessageType()
Gets RemoteMessagePlatform type whether ADM_REMOTE_MESSAGE or FCM_REMOTE_MESSAGE- Returns:
- RemoteMessagePlatform String
-
getData
@NonNull public java.util.Map<java.lang.String,java.lang.String> getData()
Gets data message payload sent by developer as key-value pair- Returns:
- Map of Key value pair
-
getNotification
public Notification getNotification()
Gets the notification from message if set- Returns:
- A3L notification object
-
getCollapseKey
public java.lang.String getCollapseKey()
Gets the collapse key of the message- Returns:
- CollapseKey
-
getFrom
public java.lang.String getFrom()
Get the sender of this message- Returns:
- Sender of message
-
getMessageId
public java.lang.String getMessageId()
Gets the message's ID- Returns:
- Message ID
-
getMessageType
public java.lang.String getMessageType()
Gets the type of message- Returns:
- Message Type
-
getOriginalPriority
public int getOriginalPriority()
Gets the original priority of message- Returns:
- Original Priority Enum
-
getPriority
public int getPriority()
Gets the priority of message as delivered- Returns:
- Priority of the delivered message
-
getSenderId
public java.lang.String getSenderId()
Gets the Sender ID for the sender of this message- Returns:
- Sender ID
-
getSentTime
public long getSentTime()
Gets the time in milliseconds from the Epoch that the message was sent- Returns:
- Time in milliseconds
-
getTo
public java.lang.String getTo()
Gets the message destination- Returns:
- Message destination string
-
getTtl
public int getTtl()
Gets the message time to live (TTL) in seconds- Returns:
- Message time to live (TTL) in seconds
-
-